﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace D20.Entities.Characters
{
    /// <summary>
    /// A creature's base abilities.
    /// </summary>
    public class Abilities
    {
        /// <summary>
        /// Gets or sets the strength.
        /// </summary>
        /// <value>The strength.</value>
        [CLSCompliant(false)]
        public uint Strength { get; set; }
        /// <summary>
        /// Gets the strength modifier.
        /// </summary>
        /// <value>The strength modifier.</value>
        public int StrengthModifier
        {
            get { return (int)((Strength - 10) / 2); }
        }
        /// <summary>
        /// Gets or sets the dexterity.
        /// </summary>
        /// <value>The dexterity.</value>
        [CLSCompliant(false)]
        public uint Dexterity { get; set; }
        /// <summary>
        /// Gets the dexterity modifier.
        /// </summary>
        /// <value>The dexterity modifier.</value>
        public int DexterityModifier
        {
            get { return (int)((Dexterity - 10) / 2); }
        }
        /// <summary>
        /// Gets or sets the constitution.
        /// </summary>
        /// <value>The constitution.</value>
        [CLSCompliant(false)]
        public uint Constitution { get; set; }
        /// <summary>
        /// Gets the constitution modifier.
        /// </summary>
        /// <value>The constitution modifier.</value>
        public int ConstitutionModifier
        {
            get { return (int)((Constitution - 10) / 2); }
        }
        /// <summary>
        /// Gets or sets the intelligence.
        /// </summary>
        /// <value>The intelligence.</value>
        [CLSCompliant(false)]
        public uint Intelligence { get; set; }
        /// <summary>
        /// Gets the intelligence modifier.
        /// </summary>
        /// <value>The intelligence modifier.</value>
        public int IntelligenceModifier
        {
            get { return (int)((Intelligence - 10) / 2); }
        }
        /// <summary>
        /// Gets or sets the wisdom.
        /// </summary>
        /// <value>The wisdom.</value>
        [CLSCompliant(false)]
        public uint Wisdom { get; set; }
        /// <summary>
        /// Gets the wisdom modifier.
        /// </summary>
        /// <value>The wisdom modifier.</value>
        public int WisdomModifier
        {
            get { return (int)((Wisdom - 10) / 2); }
        }
        /// <summary>
        /// Gets or sets the charisma.
        /// </summary>
        /// <value>The charisma.</value>
        [CLSCompliant(false)]
        public uint Charisma { get; set; }
        /// <summary>
        /// Gets the charisma modifier.
        /// </summary>
        /// <value>The charisma modifier.</value>
        public int CharismaModifier
        {
            get { return (int)((Charisma - 10) / 2); }
        }
    }
}
